import * as mongoose from 'mongoose';
import db from './../core/db/mongodb';

let menuSchema: mongoose.Schema = new mongoose.Schema(
    {
        name: String,
        user: Object,
        back: String,
        json: Array
        
    }, { collection: 'menu' , timestamps: { createdAt: 'createDate', updatedAt: 'updateDate' } });
export interface Menu extends mongoose.Document {
    name: string,
    user: any,
    back: any,
    json: any
}
export let menuModel = db.model<Menu>('menu', menuSchema);
